<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .box {
            text-align: center;
            line-height: 400px;

        }
    </style>
</head>

<body>
    <div class="box">你真是个天才！</div>
    <button class="btn">点击高变400px</button>
    <button class="btn1">点击宽变400px</button>
    <button class="btn2">点击背景颜色变绿色</button>
    <button class="btn3">点击背景颜色变红色</button>
    <button class="btn4">点击字体颜色变黄色</button>
    <!-- 封装一个可以链式调用的函数，要求至少有三次链式调用，用于修改dom元素的style -->
</body>
<script src="./jquery-1.11.1.js"></script>
<script>
    function fn() {
        $('.box').html('你真是天才')
        alert('你真是天才')
    }
    // var box = document.querySelector('.box')
    $('.btn').on("click", function () {
        $('.box').css('height', "400")
        fn()
    })
    $('.btn1').on("click", function () {
        $('.box').css('width', "400")
    })
    $('.btn2').on("click", function () {
        $('.box').css('background', "green")
    })
    $('.btn3').on("click", function () {
        $('.box').css('background', "red")
    })
    $('.btn4').on("click", function () {
        $('.box').css('color', "yellow")
    })


</script>

</html>